package com.haoze.nurseapp.service;

import com.github.pagehelper.PageInfo;
import com.haoze.common.response.Result;
import com.haoze.nurseapp.dto.StopTaskDTO;
import com.haoze.nurseapp.dto.TaskNodeDTO;
import com.haoze.common.model.OrdersFileIndexDataEntity;
import com.haoze.nurseapp.model.AtomizeMedReturnEntity;

import java.util.List;
import java.util.Map;

public interface TaskExecuteService {

    Result getDrugsByQrcode(String firstQrCode, String nodeId, String type, String secondQrCode);

    Result doProcess(Map<String,Object> map);

    Result getWorkbenchInfo();

    List<Map<String, String>> queryTaskNum(String nodeId, String currentDate, String wardId);

    Result createBatchQrcode(Map<String,Object> map);

    Result createPivasBatchQrcode(Map<String, Object> map);

    List<OrdersFileIndexDataEntity> getOrderInfoByBarCode(String barCode);

    /**
     * 获取医嘱信息
     * @param qrCode
     * @return
     */
    Result getOrdersInfo(String qrCode);

    /**
     * 根据状态获取对应的任务列表
     * @param map
     * @return
     */
    PageInfo<Map<String, Object>> getTasks(Map<String, Object> map);

    /**
     * 1.2扫码
     * @param qrCode
     * @param ctlId
     * @param showFlag
     * @return
     */
    Result screenQrCode(String qrCode, String ctlId, String showFlag);

    /**
     * 节点确定流转及文书保存
     * @param taskNode
     * @return
     */
    Result passNode(TaskNodeDTO taskNode);

    /**
     * 根据腕带或床头牌获取待执行任务列表
     * @param qrCode
     * @param word
     * @return
     */
    Result getWaitTasks(String qrCode, int page, int pageSize, String word);

    /**
     * 核实二维码
     * @param firstQrCode
     * @param secondQrCode
     * @param showFlag
     * @return
     */
    Result checkQrCode(String firstQrCode, String secondQrCode, String nodeType, String showFlag,String uuid);

    /**
     * 任务中心获取节点信息及文书
     * @param qrCode
     * @return
     */
    Result screenQrCodeInCenter(String qrCode);

    /**
     * 根据传入值计算返回需要节点
     * @param emrFileId
     * @param varCode
     * @param dataCode
     * @param dataValue
     * @return
     */
    Result ruleFilter(String emrFileId, String varCode, String dataCode, String dataValue);

    /**
     * 工作台扫描二维码
     * @param qrCode
     * @param nodeId
     * @return
     */
    Result workSpaceScreen(String qrCode, String nodeId);

    /**
     * 获取指定日期工作日志
     * @param inpatNum
     * @param dateTime
     * @param page
     * @param pageSize
     * @return
     */
    Result getWorkLog(String inpatNum, String dateTime, int page, int pageSize, String search, String type,String orderType);

    /**
     * 获取工作日志分类数量
     * @param inpatNum
     * @param dateTime
     * @return
     */
    Result getWorkLogCount(String inpatNum, String dateTime);

    Result getEmrFileByCtlId(String qrCode, String ctlId);

    Result getEmrFileByqrCode(String qrCode);

    //boolean generatTaskByQrcode(String qrcode);
    Result  generatTaskByQrcode(String qrcode);

    String checkOrderStatus(String inpatOrderDataId, String type);

    Result generatTaskNode(String qrCode);

    Result stopTask(StopTaskDTO stopTaskDTO);

    Result queryTaskStatusByQrCode(StopTaskDTO stopTaskDTO);
    Result queryTaskPuncturePointByQrCode(StopTaskDTO stopTaskDTO);

    Result deletePuncturePoint(String inpatNum, String pointValue);


}
